home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / comm / bytecomm.zip / COMM.H < prev    next >
Text File  |  1991-07-18  |  5KB  |  190 lines

  1.  
  2. /*      comm.h     */
  3.  
  4.  
  5. #define     TRUE           1
  6. #define     FALSE          0
  7. #define     LT            <0
  8. #define     EQ           ==0
  9. #define     GT            >0
  10. #define     NE           !=0
  11.  
  12. #define     MY_STK_SIZE 1024
  13. #define     LINE_LENGTH   81
  14. #define     MAX_LINES    100
  15.  
  16. #define     SBUFSIZ     6000
  17. #define     OBUFSIZ     1100
  18.  
  19. #define     NO_TRANSFER    0
  20. #define     ASCII_RECV     1
  21. #define     ASCII_SEND     2
  22. #define     XMODEM_RECV   11
  23. #define     XMODEM_SEND   12
  24. #define     YMODEM_RECV   21
  25. #define     YMODEM_SEND   22
  26. #define     KERMIT_RECV   31
  27. #define     KERMIT_SEND   32
  28.  
  29. #define     NORMAL         1
  30. #define     CHAT           2
  31. #define     ANSI           3
  32.  
  33. #define     ALT           56
  34. #define     RIGHT_SHIFT   54
  35.  
  36. #define     SOH         0x01
  37. #define     STX         0x02
  38. #define     EOT         0x04
  39. #define     ACK         0x06
  40. #define     NAK         0x15
  41. #define     YSTART       'C'
  42.  
  43. #define     BELL           7
  44. #define     BS             8
  45. #define     LINEFEED      10
  46. #define     FORMFEED      12
  47. #define     CR            13
  48. #define     TAB            9
  49. #define     BACKTAB       15
  50. #define     CTRLQ         17
  51. #define     CTRLS         19
  52. #define     CTRLX         24
  53. #define     CTRLZ         26
  54. #define     ESC           27
  55.  
  56. #define     ALTX          45
  57. #define     ALTC          46
  58. #define     ALTS          31
  59. #define     ALTD          32
  60. #define     ALTE          18
  61. #define     ALTF          33
  62. #define     ALTT          20
  63. #define     ALTM          50
  64. #define     ALTH          35
  65. #define     ALT1         120
  66. #define     ALT2         121
  67. #define     ALT3         122
  68. #define     ALT4         123
  69. #define     ALT5         124
  70. #define     ALT6         125
  71. #define     ALT7         126
  72. #define     ALT8         127
  73. #define     ALT9         128
  74. #define     HOMEKEY       71
  75. #define     ENDKEY        79
  76. #define     UPKEY         72
  77. #define     DOWNKEY       80
  78. #define     PGUPKEY       73
  79. #define     PGDNKEY       81
  80. #define     LEFTKEY       75
  81. #define     INSKEY        82
  82. #define     RIGHTKEY      77
  83. #define     DELKEY        83
  84. #define     CTRLLEFTKEY  115
  85. #define     CTRLRIGHTKEY 116
  86. #define     F1            59
  87. #define     F2            60
  88. #define     F3            61
  89. #define     F4            62
  90. #define     F5            63
  91. #define     F6            64
  92. #define     F7            65
  93. #define     F8            66
  94. #define     F9            67
  95. #define     F10           68
  96.  
  97. #define     BLACK          0
  98. #define     BLUE           1
  99. #define     GREEN          2
  100. #define     CYAN           3
  101. #define     RED            4
  102. #define     MAGENTA        5
  103. #define     BROWN          6
  104. #define     WHITE          7
  105. #define     DARKGRAY       8
  106. #define     LIGHTBLUE      9
  107. #define     LIGHTGREEN    10
  108. #define     LIGHTCYAN     11
  109. #define     LIGHTRED      12
  110. #define     LIGHTMAGENTA  13
  111. #define     YELLOW        14
  112. #define     BRIGHTWHITE   15
  113. #define     BLINK        128
  114. #define     HIGHINTENSITY 15
  115. #define     UNDERLINE      1
  116.  
  117. #define     MONO           0
  118. #define     CGA            1
  119. #define     EGA            2
  120.  
  121. #define HWM             SBUFSIZ / 4 * 3
  122. #define LWM             SBUFSIZ / 2
  123. #define XOFF            0x13
  124. #define XON             0x11
  125.  
  126. #define CTS             0x10
  127. #define DSR             0x20
  128. #define RI              0x40
  129. #define CD              0x80
  130. #define DTR             0x01
  131. #define RTS             0x02
  132. #define OUT2            0x08
  133. #define THR_BUSY        0x20
  134. #define IMR             0x21
  135. #define ICR             0x20
  136. #define EOI             0x20
  137. #define IRQ3            0xf7
  138. #define IRQ4            0xef
  139. #define RX_INT             3
  140. #define RTS_DTR         0x0b
  141.  
  142. #define MAX_BAUD       38400l
  143. #define NO_PAR             0
  144. #define EV_PAR             1
  145. #define OD_PAR             2
  146.  
  147. void    do_popup(void);
  148. void    do_transfer(void);
  149. void    actual_popup(void);
  150. int     get_vid_mode(void);
  151. void    getkey(void);
  152. void    vidtype(void);
  153. int     kbdstring(char buff[], int max_chars);
  154. int     fgetbuf(int fh);
  155. int     fgetstring(int fh, char buff[], int max_chars);
  156. void    message(char *s);
  157. void    ask_yn(char *s);
  158. void    beep(void);
  159.  
  160.  
  161. /*
  162.  *
  163.  *  kermit prototypes
  164.  *
  165.  *
  166.  */
  167.  
  168. int    bufemp       (char [], int);
  169. int    bufill       (char []);
  170. int    gnxtfl       (void);
  171. char   rdata        (void);
  172. void   read_tty     (unsigned char *);
  173. void   recsw        (void);
  174. char   rfile        (void);
  175. char   rinit        (void);
  176. char   rpack        (int *, int *, char *);
  177. int    rpar         (char []);
  178. char   sbreak       (void);
  179. char   sdata        (void);
  180. void   sendsw       (void);
  181. char   seof         (void);
  182. char   sfile        (void);
  183. char   sinit        (void);
  184. int    spack        (char, int, int, char *);
  185. int    spar         (char []);
  186. void   write_tty    (char *, int);
  187.  
  188.  
  189.  
  190.